gdk_synthesize_window_state (window, GDK_WINDOW_STATE_FOCUSED, 0);
}
+static void
+xdg_surface_delete (void *data,
+ struct xdg_surface *xdg_surface)
+{
+ GdkWindow *window = GDK_WINDOW (data);
+ GdkDisplay *display;
+ GdkEvent *event;
+
+ display = gdk_window_get_display (window);
+
+ event = gdk_event_new (GDK_DELETE);
+
+ event->any.window = window;
+ event->any.send_event = TRUE;
+
+ _gdk_wayland_display_deliver_event (display, event);
+}
+
static const struct xdg_surface_listener xdg_surface_listener = {
xdg_surface_ping,
xdg_surface_configure,
xdg_surface_request_unset_maximized,
xdg_surface_focused_set,
xdg_surface_focused_unset,
+ xdg_surface_delete,
};
static void
decorations should be updated accordingly.
</description>
</event>
+
+ <event name="delete">
+ <description summary="surface wants to be closed">
+ The delete event is sent by the compositor when the user
+ wants the surface to be closed. This should be equivalent to
+ the user clicking the close button in client-side decorations,
+ if your application has any...
+
+ This is only a request that the user intends to close your
+ window. The client may choose to ignore this request, or show
+ a dialog to ask the user to save their data...
+ </description>
+ </event>
</interface>
<interface name="xdg_popup" version="1">